xl: enable using ranges of pCPUs when manipulating cpupools
authorDario Faggioli <dario.faggioli@citrix.com>
Fri, 13 Mar 2015 11:09:32 +0000 (12:09 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Wed, 18 Mar 2015 12:51:14 +0000 (12:51 +0000)
commit62ff09ae2f8c77998ce500ba3d16b2f33aeb9010
tree0033faf74b00adb741af43ee5881326e79c85c4a
parent7f586dbb483962835b6cb7d6918dcfca95c5437d
xl: enable using ranges of pCPUs when manipulating cpupools

in fact, right now, xl sub-commands 'cpupool-cpu-add' and
'cpupool-cpu-remove' only accept the specification of one
pCPU to be added or removed to/from a cpupool.

With this change, they can deal with ranges, like "4-8",
or "node:1,12-18,^14". The syntax is exactly the same one
that is supported by the 'vcpu-pin' subcommand, and
specifying just one pCPU still works, of course.

This make things more flexible, more consistent, and also
improves error handling, as the pCPU range parsing routine
already present in xl is more reliable than just a call
to atoi().

Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com>
Cc: Ian Campbell <ian.campbell@citrix.com>
Cc: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
Cc: Juergen Gross <JGross@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
docs/man/xl.pod.1
tools/libxl/xl_cmdimpl.c